package com.wan.adapter

import android.support.v4.app.Fragment
import android.support.v4.app.FragmentManager
import android.support.v4.app.FragmentPagerAdapter

class ProjectVpAdapter(fm: FragmentManager?, private var fragments:ArrayList<Fragment>, var titles:ArrayList<String>) : FragmentPagerAdapter(fm){
    override fun getItem(position: Int): Fragment {
        return  fragments[position]
    }

    override fun getCount(): Int {
        return fragments.size
    }

    override fun getPageTitle(position: Int): CharSequence? {
        return titles[position]
    }
}